import Vue from 'vue';
import iView from 'iview';
import VueRouter from 'vue-router';
import CptToolkit from 'cpt-toolkit';

import app from './components/app';
import store from './store';
import router from './routes';
import './styles/index.less';

Vue.use(VueRouter);
Vue.use(iView);
Vue.use(CptToolkit);

const debug = process.env.NODE_ENV !== 'production';
Vue.config.debug = debug;
Vue.config.devtools = debug;
Vue.config.productionTip = debug;
window._vueInstance = new Vue({
  debug,
  el: '#app',
  components: { app },
  template: '<app/>',
  store,
  router
});
